﻿Imports System.Net.Mail
Imports Equipment.Core

''' <summary>
''' A factory for all dependences like <see cref="SmtpClient"/>
''' </summary>
Public NotInheritable Class DependenciesFactory
    Private Sub New()
    End Sub
    ''' <summary>
    ''' Returns a concrete implementation of <see cref="ISmtpClient"/>
    ''' </summary>
    ''' <returns></returns>
    Public Shared Function GetSmtpClient() As ISmtpClient
#If DEBUG Then
        Return New TestSmtpClient()
#Else
        Dim smptServerHost = Sys.SmtpServer

        Return New StandardSmtpClient(smptServerHost)
#End If
    End Function
End Class
